﻿#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>
int main()
{
	int arr1[100];
	int arr2[1000] = { 0 };
	int i = 0;
	int t = 0;
	while (~scanf("%d", &arr1[i++]))
	{
		t++;
	}
	for (i = 0; i < t; i++)
	{
		arr2[arr1[i]]++;
	}
	t = 0;
	for (i = 0; i < 1000; i++)
	{
		if (arr2[i] == 1)
		{
			t++;
			printf("%d ", i);
		}
		if (t == 2)
			break;
	}
	return 0;
}